package com.lunchspothack;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;

public class LunchspotActivity extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
    }
    
    public boolean onCreateOptionsMenu(Menu menu) {
        // Create items from locationmailermenu.xml
        MenuInflater inflater = getMenuInflater();
        inflater.inflate(R.menu.main_menu, menu);
        return true;
    }
    
    // Called when an options item is clicked
    public boolean onOptionsItemSelected(MenuItem item) {
        switch (item.getItemId()) {

        // Show Checkins Places list screen
        case R.id.menuCheckinsView:
            startActivity(new Intent(getApplicationContext(), ViewCheckinsActivity.class)
                    .addFlags(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT));
            break;
        }


        return true;
    }

}